/**
 * {
  "category3Id": 0,
  "createTime": "2022-11-23T07:22:34.502Z",
  "id": 0,
  "isSale": 0,
  "price": 0,
  "skuAttrValueList": [
    {
      "attrId": 0,
      "attrName": "string",
      "id": 0,
      "skuId": 0,
      "valueId": 0,
      "valueName": "string"
    }
  ],
  "skuDefaultImg": "string",
  "skuDesc": "string",
  "skuImageList": [
    {
      "id": 0,
      "imgName": "string",
      "imgUrl": "string",
      "isDefault": "string",
      "skuId": 0,
      "spuImgId": 0
    }
  ],
  "skuName": "string",
  "skuSaleAttrValueList": [
    {
      "id": 0,
      "saleAttrId": 0,
      "saleAttrName": "string",
      "saleAttrValueId": 0,
      "saleAttrValueName": "string",
      "skuId": 0,
      "spuId": 0
    }
  ],
  "spuId": 0,
  "tmId": 0,
  "weight": "string"
}
 */

export interface SkuSaleAttrValueItem {
  saleAttrId: number;
  saleAttrName: string;
  saleAttrValueId: number;
  saleAttrValueName: string;
  skuId?: number;
  spuId?: number;
  id?: number;
}

export type SkuSaleAttrValueList = Array<SkuSaleAttrValueItem | string>;

export interface SkuImageItem {
  id: number;
  imgName: string;
  imgUrl: string;
  isDefault: string;
  skuId: number;
  spuImgId: number;
}

export type SkuImageList = SkuImageItem[];

export interface SkuAttrValueItem {
  attrId: number;
  attrName: string;
  id?: number;
  skuId?: number;
  valueId?: number;
  valueName: string;
}

export type SkuAttrValueList = Array<SkuAttrValueItem | string>;

export interface SkuItem {
  skuName: string;
  weight: number;
  price: number;
  skuDesc: string;
  skuAttrValueList: SkuAttrValueList;
  skuDefaultImg: string;
  skuImageList: SkuImageList;
  skuSaleAttrValueList: SkuSaleAttrValueList;
  spuId?: number;
  id?: number;
  category3Id?: number;
}

export type SkuList = SkuItem[];
